import jsonpath

class GetKeyWord:
    @staticmethod
    def get_keyword(data,keyword):
        if jsonpath.jsonpath(data,f'$..{keyword}'):
            return jsonpath.jsonpath(data,f'$..{keyword}')[0]
        else:
            return False

    @staticmethod
    def get_keywords(data,keyword):
        return jsonpath.jsonpath(data,f'$..{keyword}')